﻿<%@Register Assembly="CKEditor.NET" Namespace="CKEditor.NET" TagPrefix="CKEditor"%><%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Admin.Master" AutoEventWireup="true" CodeBehind="themtintuc.aspx.cs" Inherits="NCKH.Admin.themtintuc" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
 <style type="text/css">
        .auto-style1 {
            width: 136px;
        }
        .auto-style2 {
            width: 136px;
            height: 11px;
        }
        .auto-style3 {
            height: 11px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <fieldset>
 <legend style="text-align:center"><H3>THÊM TIN TỨC</H3></legend>
    <table>

   <tr>
       <td class="auto-style1"></td>
       <td>
           <asp:TextBox ID="txtmatin" Width="136px" Height="20px"
     Visible="false" runat="server" OnTextChanged="txtmatin_TextChanged"></asp:TextBox>
       </td>
   </tr>
    <tr>
        <td class="auto-style1">
            Tên nhóm tin
        </td>
        <td>
<asp:DropDownList ID="ddlnhomtin" runat="server"  Width="167px" OnSelectedIndexChanged="ddlnhomtin_SelectedIndexChanged" Height="26px"></asp:DropDownList>
        </td>
    </tr>
     <%--<asp:Label ID="lblthongbaotin" runat="server"></asp:Label>--%>
  
        <tr>
            <td class="auto-style1">
                Tên danh mục tin
            </td>
            <td>
                <asp:DropDownList ID="ddldanhmuctin" runat="server" Height="26px" Width="172px" OnSelectedIndexChanged="ddldanhmuctin_SelectedIndexChanged"></asp:DropDownList>
            </td>
        </tr>
    
          <tr>
              <td class="auto-style2">
                    Tiêu đề
              </td>
              <td class="auto-style3">
                  <asp:TextBox ID="txttieude" runat="server" Width="544px" Height="24px" OnTextChanged="txttieude_TextChanged"></asp:TextBox>
                   <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"
                        ControlToValidate="txttieude" Display="Dynamic" ErrorMessage="Không được bỏ trống">Không được bỏ trống</asp:RequiredFieldValidator> 
              </td>
          </tr>
        <tr>
            <td class="auto-style1">
                Tóm tắt
            </td>
            <td>
                <asp:TextBox ID="txttomtat" runat="server" Height="126px" Width="537px" OnTextChanged="txttomtat_TextChanged" TextMode="MultiLine"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" Display="Dynamic" 
                ControlToValidate="txttomtat" ErrorMessage="Tóm tắt không được bỏ trống">Không được bỏ trống</asp:RequiredFieldValidator>
            </td>
        </tr>

          <tr>
              <td class="auto-style1">
                  Nội dung
              </td>
              <td>
                  
                  <ckeditor:ckeditorcontrol ID="txtnoidung" runat="server" Height="239px" Width="540px" OnTextChanged="txtnoidung_TextChanged"></ckeditor:ckeditorcontrol>
              </td>
          </tr>
  
  <tr>
      <td class="auto-style1">
          Image
      </td>
      <td>
           <asp:FileUpload ID="fileupload1"  runat="server" Width="539px" />
          <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" Display="Dynamic" 
                ControlToValidate="fileupload1" ErrorMessage="phải upload ảnh lên!!">Phải up ảnh lên!!</asp:RequiredFieldValidator>
      </td>
  </tr>
        <tr>
            <td class="auto-style1">
                Tag
            </td>
            <td>
                <asp:TextBox ID="txtTag" Height="20px" Width="534px" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server"  Display="Dynamic"
                ControlToValidate="txtTag" ErrorMessage="Tag không được bỏ trống">Tag ko được bỏ trống</asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="auto-style1">
                Hiển thị
            </td>
            <td>
                <asp:DropDownList ID="drhienthi" runat="server" Width="61px" Height="27px">
                     <asp:ListItem Text="True">True</asp:ListItem>
                        <asp:ListItem Text="False">False</asp:ListItem>
                      </asp:DropDownList>
            </td>
        </tr>
        <tr>
            <td>
                Trạng thái tin
            </td>
            <td>
                <asp:DropDownList ID="drdtrangthai" runat="server" Width="61px" Height="27px">
                    <asp:ListItem Text="tin hot">HOT</asp:ListItem>
                     <asp:ListItem Text="tin mới">NEW</asp:ListItem>
                    <asp:ListItem Text="tin thường">thường</asp:ListItem>
                </asp:DropDownList>
            </td>
        </tr>
        <tr>
            <td class="auto-style1">

            </td>
            <td>
                 <asp:Button ID="btnthemtin" runat="server" Text="Thêm tin" CausesValidation="false" onclick="btnthemtin_Click" Height="30px" Width="88px" />
   
                  <asp:Button ID="btnhuy" Text="Hủy" runat="server" CausesValidation="False" onclick="btnhuy_Click" Width="77px" Height="30px" />
            </td>
        </tr> 
          </table> 
        <asp:Label ID="lbltb" runat="server"></asp:Label>      
 </fieldset>
       
</asp:Content>
